package com.gabry.examples;

/**
 * Created by ShaoJie.Wu on 2017/1/11 9:19.
 * 功能：
 * <p>
 * 备注：
 */
public class ClassA extends ISayHello {
    private ISayHello otherClass = null;
    public ClassA(ISayHello otherClass){
        this.otherClass = otherClass;
    }

    @Override
    public void SayHello(){
       // StackUtil.getInstance().stack();
        System.out.println("Hi ,I'm in ClassA");
        if(otherClass!=null){
            otherClass.SayHello();
        }
    }
}
